#include <stdio.h>

void swap(int a, int b)
{
	int t;

	t = a;
	a = b;
	b = t;
}

void swap2(int *ap, int *bp)
{
	int t;

	t = *ap;
	*ap = *bp;
	*bp = t;
}

int main()
{
	int a = 3;
	int b = 4;

	swap(a, b);
	printf("swap: %d, %d\n", a, b);
	swap2(&a, &b);
	printf("swap2: %d, %d\n", a, b);
	return 0;
}
